#
# Makefile for carrot
#     -- bootloader for bunny in rabbitos project
# Tan Menglong <tanmenglong@gmail.com>
# 2009-02-06
# 
# Commands to make disk image:
# * Make an empty image
#   dd if=/dev/zero of=emptydisk.img bs=512 count=2880
# * Make an image of data file
#   dd if=carrot.bin of=carrot.img bs=512 count=1
# * Add zeroed data to the end to make an image with poper size 
#   dd if=emptydisk.img of=carrot.img skip=1 seek=1 bs=512 count=2879
# 

CC=gcc
LD=ld
AS=as
LDSCRIPT=carrot.ld
DEBUG_DIR=../../debug/
INCLUDE_DIR=../include/

all:loader.bin

loader.bin:loader.o
	$(LD) -Tloader.ld loader.o -o loader.bin
loader.o:loader.S
	$(CC) -c -I$(INCLUDE_DIR) -o loader.o loader.S

clean:
	rm -rf *.bin *.o








